<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!DOCTYPE html>
<html>
<head>
<jsp:include page="title.jsp"/>
<meta charset="utf-8"/>
 <meta name="keywords" content="贷款，信用贷，分期，借款，万八千，信用借款，借款5000元，小额现金贷" />
  <meta name="description" content="万八千提供快速的小额借款服务。可以借款5000元、无抵押、无担保、万八千是一款针对成人白领市场的消费金融产品，通过互联网、大数据等科技手段，为用户提供短期的信用借贷，解决用户资金周转问题。"/>
<link href="css/style.css" rel="stylesheet"/>
<link rel="stylesheet" type="text/css" href="css/normalize.css" />
<link rel="stylesheet" type="text/css" href="css/default.css">
<link href="css/jquery.ui.datepicker.css" rel="stylesheet" type="text/css" />
<script src="js/jqbase.js"></script>
<script type="text/javascript" src="js/jquery-1.8.3.js"></script>


<script type="text/javascript" src="myjs/city-picker.data.js" ></script>
<script type="text/javascript" src="myjs/city-picker.js" ></script>
<link rel="stylesheet" href="myjs/city-picker.css" />
<script type="text/javascript" src="js/jquery.ui.core.js"></script>
<script type="text/javascript" src="js/jquery.ui.datepicker.js"></script>
</head>
<body style="background:#eaedf1;">
<jsp:include page="top.jsp"/>
	<div class="backstage no-mar">
		<div class="chose_btn clearfix">
			<a href="" class="frash fl"><img src="img/frash.png"></a>
			<!--<input placeholder="内容关键词" value="${pager.key }" class="fl key_words" id="key">-->
	<div style="position: relative;"><!-- container -->  
   <input readonly type="text" id="key" name="address" data-toggle="city-picker" style="width:35%;">     
			<button value="" id="search">搜索</button>
			<button value="" id="update">批量修改</button>
			</div>
		</div> 
		<table class="caozuo audit">
			<tr>
				
				<th class="w3">地区编号</th>
				<th class="w3">当前名称</th>
				<th class="w3">上级编号</th>
				<th class="w3">省市区全称</th>
				<th class="w3">层级</th>
				<th class="w3">启动状态</th>
				<th class="w3">操作</th>
			</tr>
		<c:forEach items="${pager.list }" var="area">
			<tr>
				
				<td>${area.areaNo }</td>
				<td>${area.areaName }</td>
				<td>${area.parentAreaNo }</td>
				<td>${area.areaFullName }</td>
				<td>${area.areaLevel }</td>
				<td>
				<c:if test="${area.areaStatus==0 }">禁用</c:if>
				<c:if test="${area.areaStatus==1 }">启用</c:if>
				</td>
				<td>
                  <c:if test="${area.areaStatus==0 }"><a href="updateStatusByarea?areaNo=${area.areaNo }">启用</a></c:if>
                  <c:if test="${area.areaStatus==1 }"><a href="updateStatusByarea1?areaNo=${area.areaNo }">禁用</a></c:if>
                 
               </td>
			</tr>
		</c:forEach>
		</table>
		<p class="tongji">共${pager.totalRow }条</p>
		 <div class="page clearfix">
		 <div ><font color="red">${pager.tot}</font></div>
                <div class="page clearfix">
                <div class="page-link fl">
                    <a href="area.html?page=1&pageSize=${pager.pageSize }&userId=${pager.userId}&key=${pager.key}">首页</a>
                    <a href="area.html?page=${pager.page-1 }&pageSize=${pager.pageSize }&userId=${pager.userId}&key=${pager.key}">上一页</a>
                    <a class="active" href="#">${pager.page }</a>
                    <a href="area.html?page=${pager.page+1 }&pageSize=${pager.pageSize }&userId=${pager.userId}&key=${pager.key}">下一页</a>
                    <a href="area.html?page=${pager.totalPage }&pageSize=${pager.pageSize }&userId=${pager.userId}&key=${pager.key}">尾页</a>
                </div>
                <div class="page-info fl">共<span>${pager.totalRow }</span>条信息&nbsp;&nbsp;当前显示第<span>${pager.page }</span>页</div>
            </div>
	</div>
<jsp:include page="foot.jsp"/>
<jsp:include page="left.jsp"/>
<script type="text/javascript">
$(function(){
	$("#search").click(function(){
		var key=$("#key").val();
		key = key.replace(/\//g,",");
		alert(key)
		window.location.href="area.html?page=${pager.page}&&pageSize=${pager.pageSize }&userId=${pager.userId}&key="+key;
	});
	
	
	$("#update").click(function(){
		window.location.href="toupdateArea.html";
		
		
	});
})

</script>
</body>
</html>